:root {
  --small-margin-side:  16px;
  --max-width:          800px;
  --headfoot-bg:        #4e7bbd;
  --menu-bg:            #8ba8d3;
  --menu-h:             #678dc6;
  --menu-click:         #4977bb;
  --content-bg:         #fcfcfc;
  --menu-a:             var(--content-bg);
}

body {
  font-family:  Verdana, Helvetica, Arial, sans-serif;
  text-align:   justify;
  font-size:    18px;
}

.page-content {
  margin:             0 auto;
  max-width:          var(--max-width);
  background-color:   var(--content-bg);
}

h1 {
  background-color:   var(--headfoot-bg);
  color:              orange;
  text-shadow:        black 2px 2px 3px;
  margin:             0;
  padding:            24px;
  text-align:         center;
}

.footer {
  background-color:   var(--headfoot-bg);
  font-size:          smaller;
  padding:            16px;
  color:              white;
}
.footer-content {
  margin:             auto;
  max-width:          var(--max-width);
}

.content {
  padding:          16px;
}

/* details (collapsible panel)) */
details {
  border: 1px solid #aaaaaa;
  border-radius: 4px;
  padding: 8px 8px 0;
  margin: 0 -12px 16px;
}

summary {
  font-weight: bold;
  margin: -8px -8px 0;
  padding: 0.5em;
}

details[open] {
  padding: 8px;
}

details[open] summary {
  border-bottom: 1px solid #aaaaaa;
  margin-bottom: 0.5em;
}
/* end of details */


/* Menu */

.menu-container {
  display:              flex;
  justify-content:      space-between;
  background-color:     var(--menu-bg);
  width:                100%;
}
.menu {
  text-align:           center;
}
.menu div {
  display:              inline-block;
  padding:              8px;
  &:hover {
    background-color:   var(--menu-h);
  }
  &:active {
    background-color:   var(--menu-click);
  }
  &.active {
    color:              orange;
    background-color:   var(--menu-a);
    a {
      color:            darkorange;
    }
  }
}
.menu a {
  font-size:            1.5em;
  &.active {
    color:              white;
  }
  &:active {
    background-color:   var(--menu-click);
    color:              white;
  }
}
.menu a:link {
  text-decoration:    none;
}
.menu a:hover {
  text-decoration:    none;
}

.todo {
  font-style:       italic;
  color:          darkgreen;
}

.draft-badge {
  background-color: #ff5555;
  color:            white;
  border-radius:      12px;
  padding:            2px 10px 2px 10px;
  font-size:          14px;
  vertical-align:     top;
}

/* Route cards in trips */
.route-cards {
  /*display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: flex-start;
  margin: 2rem 0;*/
}

.route-card {
  /* background: #fff; */
  border: 1px solid #eee;
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  padding: 0 1rem;
  margin-bottom: 1rem;
  /*min-height: 100px;*/
  /*display: flex;
  flex-direction: column;
  justify-content: space-between;*/
  transition: box-shadow 0.2s;

  h3 {
    margin-top: 0.3rem;
    margin-bottom: 0.2rem;
    text-align: left;
  }
}

.route-card:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
}

.route-meta {
  display: flex;
  justify-content: flex-start;
  gap: 1.2em;
  font-size: 0.8em;
  font-style: italic;
  color: #666;
  margin-top: auto;
  padding-top: 0.1em;
  border-top: 1px solid #eee;
}

/* End of route cards in trips */



.route-image {
  max-width:          100%;
  margin-left:        auto;
  margin-right:       auto;
  display:            block;
}

.route-map iframe {
  margin-left:        var(--small-margin-side);
  margin-right:       var(--small-margin-side);
  width:              calc(100% - 2*var(--small-margin-side));
  display:            block;  
}

.details-map {
  width:              calc(100% - 2*var(--small-margin-side));
  margin:             auto;
  iframe {
    width:            100%;
  }
}

.route-core-data {
  margin:             4px var(--small-margin-side) 8px var(--small-margin-side);
  border:             1px solid darkgray;
  background-color: lightgray;
  padding:            8px;
}

h3 {
  margin-top: 40px;
}

.under-h3 {
  margin-top: -18px;
  margin-bottom: 17px;
}

.dates-hint {
  font-style: italic;
  color: gray;
}

.popup-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  overflow: hidden;

  height: 0px;
  border: none;

  .tracking-inside {
    position: inherit;
    left: 50%;
    height: 100%;
    margin-left: -250px;
    border: 1px gray solid;
    background-color: lightgray;
    color: black;
    padding: 12px 35px;
  }
  .buttons {
    text-align: center;
    margin-top: 6px;
    button {
      appearance: button;
      backface-visibility: hidden;
      border-radius: 6px;
      border-width: 0;
      box-sizing: border-box;
      cursor: pointer;
      outline: none;
      touch-action: manipulation;
      font-size: large;
      padding: 6px 12px;
    }
    .primary {
      margin: 0px 12px;
      background-color: #415ef6;
      color: #fff;
    }
  }

  transition: 1s;
}
.popup-bottom-appear {
  height: 120px;
}


.language {
  width:                50px;
  display:              flex;
  align-items:          center;
}

/* FLAGS */
.flag {
  width:                40px;
  height:               40px;
  overflow:             hidden;  /* Ensures child divs don’t overflow */
  position:             relative;
  display:              inline-block;
  &:hover {
    box-shadow:        black 0 0 4px;
  }
  &:active {
    box-shadow:        white 0 0 5px;
  }
}
.flag-de {
  border-radius:        50%; /*50% 20% 20% 50%;*/
  margin-right:         10px;
}
.flag-uk {
  border-radius:        50% /*20% 50% 50% 20%*/;
  margin-right:         5px;
}

.uk-top {
  background: #0056B9; /* Blue color */
  width:      100%;
  height:     50%;
  position:   absolute;
  top:        0;
}

.uk-bottom {
  background: #FFD800; /* Yellow color */
  width:      100%;
  height:     50%;
  position:   absolute;
  bottom:     0;
}

.de-top, .de-middle, .de-bottom {
  width:      100%;
  height:     34%;  /* Each stripe takes 1/3 of the circle, but don't cut bottom because of rounding */
}

.de-top, .de-bottom {
  background: #C8102E; /* Red stripes */
}

.de-middle {
  background: white; /* White stripe */
}